package com.southwind.mapper;

import com.southwind.entity.Worker;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author admin
 * @since 2024-07-04
 */
public interface WorkerMapper extends BaseMapper<Worker> {

    @Select({"select username from worker where id = #{id} "})
    public String getNameById(Integer id);

    @Update({"update worker set status = #{status} where id = #{id}"})
    public Integer updateStatus(String status,Integer id);
}
